import { ResponseData } from '@/API/user/type.js'
export interface UserListResponseData extends ResponseData {
  data: UserListData
}

export interface UserListData {
  records: RecordUserData[]
  total?: number
  size?: number
  current?: number
  orders?: []
  optimizeCountSql?: boolean
  hitCount?: boolean
  countId?: null
  maxLimit?: null
  searchCount?: boolean
  pages?: number
}
export type RecordUserData = Record[]

export interface Record {
  id?: number | string
  createTime?: string
  updateTime?: string
  username?: string
  password?: string
  name?: string
  phone?: null
  roleName?: string
}
export interface User extends Record {}

export interface SaveUserResponseData extends ResponseData {
  data: null
}
export interface UpdataUserResponseData extends ResponseData {
  data: null
}
export interface DelUserResponseData extends ResponseData {
  data: null
}

export interface HasAdminResponseData extends ResponseData {
  data: admin
}

export interface admin {
  assignRoles: AssignRoleData
  allRolesList: AssignRoleData
}

export type AssignRoleData = AssignRole[]

export interface AssignRole {
  id: number
  createTime: string
  updateTime: string
  roleName: string[]
  remark: null
}
export interface SaveAdminRolesResponseData extends ResponseData {
  data: null
}
export interface roleVo {
  roleIdList: number[]
  userId: number |string
}
export interface SelectIdDelUserResponseData extends ResponseData {
  data: null
}
